Ubuntu 22.04 + Surface Go + Hudiy (Running Over Ubuntu)

Copy & paste the commands below directly into Terminal.


0. Install curl (REQUIRED)

sudo apt update
sudo apt install -y curl

1. Update Ubuntu

sudo apt update && sudo apt upgrade -y
sudo reboot

2. Install linux-surface Kernel

curl -s https://raw.githubusercontent.com/linux-surface/linux-surface/master/pkg/setup.sh | sudo bash
sudo apt install linux-surface linux-surface-secureboot-mok
sudo reboot
Enroll the MOK key when prompted during reboot.

3. Verify Graphics

sudo apt install mesa mesa-utils
glxinfo | grep "OpenGL renderer"

4. Install Firmware (Wi‑Fi)

sudo apt install linux-firmware
sudo reboot

5. Install Hudiy Dependencies

sudo apt install \
  wget git \
  lxc lxc-utils \
  qemu-kvm libvirt-daemon-system libvirt-clients \
  bridge-utils \
  adb
sudo systemctl enable --now libvirtd
sudo usermod -aG libvirt,kvm,video $USER
reboot

6. Confirm DRM Access

ls /dev/dri
card0
renderD128

7. Install Hudiy

git clone <hudiy-repo-url>
cd hudiy
./install.sh

or

sudo ./hudiy install
hudiy start

8. Notes & Limitations

Do NOT install proprietary Intel drivers or Android‑x86 kernels.

9. Troubleshooting

hudiy stop
hudiy start

kvm-ok

End of guide.


Extra: Fix “Unable to locate package linux-surface”

If you see an error like:

Unable to locate package linux-surface
Unable to locate package linux-surface-secureboot-mok

This means the linux-surface APT repository was not added correctly. Follow the steps below exactly.

1. Install required tools

sudo apt update
sudo apt install -y curl ca-certificates gnupg lsb-release

2. Re-add the linux-surface repository

curl -fsSL https://raw.githubusercontent.com/linux-surface/linux-surface/master/pkg/setup.sh | sudo bash

This step:

3. Update package lists

sudo apt update

If you see errors here (404, NO_PUBKEY, repo not found), stop and resolve them before continuing.

4. Install linux-surface packages

sudo apt install linux-surface linux-surface-secureboot-mok

5. Verify the packages exist

apt search linux-surface

You should see results such as:

linux-surface
linux-surface-secureboot-mok

6. Check repository file (advanced)

ls /etc/apt/sources.list.d/ | grep surface

Expected output:

linux-surface.list

7. Nuclear fix (last resort)

sudo rm -f /etc/apt/sources.list.d/linux-surface.list
sudo apt update
curl -fsSL https://raw.githubusercontent.com/linux-surface/linux-surface/master/pkg/setup.sh | sudo bash
sudo apt update
sudo apt install linux-surface linux-surface-secureboot-mok
After installation, reboot and enroll the MOK key when prompted.

Fix: “Unable to locate package linux-surface”

If you see errors like:

Unable to locate package linux-surface Unable to locate package linux-surface-secureboot-mok

This means the linux-surface repository is not installed or active. Follow the steps below exactly.

1. Install required tools

sudo apt update sudo apt install -y curl ca-certificates gnupg lsb-release

2. Add the linux-surface repository

curl -fsSL https://raw.githubusercontent.com/linux-surface/linux-surface/master/pkg/setup.sh | sudo bash

This command adds the linux-surface APT repository and signing key.

3. Refresh package lists

sudo apt update

4. Verify the packages exist

apt search linux-surface

You should see:

linux-surface linux-surface-secureboot-mok

5. Install linux-surface

sudo apt install linux-surface linux-surface-secureboot-mok

6. Last-resort fix (if still failing)

sudo rm -f /etc/apt/sources.list.d/linux-surface.list sudo apt update curl -fsSL https://raw.githubusercontent.com/linux-surface/linux-surface/master/pkg/setup.sh | sudo bash sudo apt update sudo apt install linux-surface linux-surface-secureboot-mok
After installation, reboot and enroll the MOK key when prompted.

Step 2 Error: 404 Not Found

If Step 2 returned a 404 error, this means the linux-surface project has changed branch names and the old URL is no longer valid.

This is not your fault. The fix is simply to use the updated URL.

✅ Corrected Step 2 (Use This Instead)

curl -fsSL https://raw.githubusercontent.com/linux-surface/linux-surface/main/pkg/setup.sh | sudo bash

The project moved from master to main, which causes the 404 error if you use the old command.

After running the corrected command

sudo apt update sudo apt install linux-surface linux-surface-secureboot-mok
If this command completes without errors, the linux-surface repository is now correctly installed. Reboot afterward and enroll the MOK key when prompted.
```html

Step 2 Still Returning 404 (Manual Fix)

If you still receive a 404 error when running the linux-surface setup script, this means the script URL is currently unavailable. You can safely add the repository manually instead.

1. Install required tools

sudo apt update
sudo apt install -y curl ca-certificates gnupg lsb-release

2. Import the linux-surface signing key

curl -fsSL https://pkg.surfacelinux.com/pubkey.gpg | sudo gpg --dearmor -o /usr/share/keyrings/linux-surface.gpg

3. Add the linux-surface repository manually

echo "deb [signed-by=/usr/share/keyrings/linux-surface.gpg] https://pkg.surfacelinux.com/ubuntu $(lsb_release -cs) main" | sudo tee /etc/apt/sources.list.d/linux-surface.list

4. Update package lists

sudo apt update

5. Install linux-surface packages

sudo apt install linux-surface linux-surface-secureboot-mok
After installation, reboot and enroll the MOK key when prompted.

Verification (optional)

apt search linux-surface

If packages appear, the repository is correctly installed.